package com.v5.mr.sort.mr.number;

import org.apache.hadoop.io.LongWritable;

//我自己的一个比较器，实现对数字的降序排序
public class MyNumberComparator extends LongWritable.Comparator {

	@Override
	public int compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2) {
		// 定义自己的排序规则：降序
		return -super.compare(b1, s1, l1, b2, s2, l2);
	}

}
